/**
 * "Visual Paradigm: DO NOT MODIFY THIS FILE!"
 * 
 * This is an automatic generated file. It will be regenerated every time 
 * you generate persistence class.
 * 
 * Modifying its content may cause the program not work, or your work may lost.
 */

/**
 * Licensee: DuKe TeAm
 * License Type: Purchased
 */
package orm;

import java.util.List;
import org.hibernate.criterion.DetachedCriteria;
import org.orm.PersistentSession;
import org.orm.criteria.*;

public class Trp_colegioDetachedCriteria extends AbstractORMDetachedCriteria {
	public final StringExpression co_id;
	public final StringExpression co_nombre;
	
	public Trp_colegioDetachedCriteria() {
		super(orm.Trp_colegio.class, orm.Trp_colegioCriteria.class);
		co_id = new StringExpression("co_id", this.getDetachedCriteria());
		co_nombre = new StringExpression("co_nombre", this.getDetachedCriteria());
	}
	
	public Trp_colegioDetachedCriteria(DetachedCriteria aDetachedCriteria) {
		super(aDetachedCriteria, orm.Trp_colegioCriteria.class);
		co_id = new StringExpression("co_id", this.getDetachedCriteria());
		co_nombre = new StringExpression("co_nombre", this.getDetachedCriteria());
	}
	
	public Trp_tipo_colegDetachedCriteria createTipo_colegCriteria() {
		return new Trp_tipo_colegDetachedCriteria(createCriteria("tipo_coleg"));
	}
	
	public Trp_socio_ecoDetachedCriteria createSocio_ecoCriteria() {
		return new Trp_socio_ecoDetachedCriteria(createCriteria("socio_eco"));
	}
	
	public Trp_provinciaDetachedCriteria createProvinciaCriteria() {
		return new Trp_provinciaDetachedCriteria(createCriteria("provincia"));
	}
	
	public Trp_cursoDetachedCriteria createTrp_cursoCriteria() {
		return new Trp_cursoDetachedCriteria(createCriteria("ORM_Trp_curso"));
	}
	
	public Trp_colegio uniqueTrp_colegio(PersistentSession session) {
		return (Trp_colegio) super.createExecutableCriteria(session).uniqueResult();
	}
	
	public Trp_colegio[] listTrp_colegio(PersistentSession session) {
		List list = super.createExecutableCriteria(session).list();
		return (Trp_colegio[]) list.toArray(new Trp_colegio[list.size()]);
	}
}

